调用首页产品
可选参数如下
New = 1,
Hot = 2, Best = 3, Special = 4, Featured = 5, Other = 6#foreach($item in $oct.GetProductstList(${currency},6,$ptype.Best))
- ${item.name}
- ${item.NormalPrice} ${item.SalePrice} Save:${item.Saveoff} off
列表页 调用面包屑导航
调用全部分类【支持无限级的调用,根据需要自己编写】 下面展示4级分类的调用
#foreach($item in $categorylist)
- ${item.name} #foreach($s in $item.SubClass) #beforeall #nodata #end
#end
很长看不懂吗?很简单 自己运行一下
调用产品列表
#set($count=0) #foreach($item in $productlist) #set($count=$count+1) #if($count%3==0) #end #end${pager}
关于分页的样式,已经内置几种样式可以自己定义
调用详情页面包屑【和分页的有点细微差别】
【通过产品的category对象来调用】
调用产品的多选属性
#foreach($item in $product.Attributes) #if($item.type=="attr_radio")$item.Name #foreach($a in $item.values) $a.value $oct.CheckValue($a.Pricefix) $a.DVPrice #end#end #if($item.type=="attr_dropdown")$item.Name#end #if($item.type=="attr_color_radio")$item.Name #foreach($a in $item.values) #end#end #if($item.type=="attr_text")#foreach($a in $item.values) $item.Name: #end#end #end
这个大家还是自己看吧 【懒得口舌了,想要之后可以私下联系我,如果更新了 我会在上面更新的】
其实之所以这样贴出来是为了大家方便,其实Octopus完全支持自定义的模板开发的 不过你要完全熟悉我的对象实体 才行
调用关联产品
调用上一个产品下一个产品
调用收藏夹
#if(${islogin}) #if(${iswishlist}) ${Oct_Favorite} #else ${Oct_Favorite} #end #else Favorite #end
调用产品放大镜
调用随机产品
#foreach($item in $oct.GetRandomProductList(${currency},3))
- $item.name
- ${item.NormalPrice} ${item.SalePrice} Save:${item.Saveoff} off
调用函数
字符截取
$oct.CutString("${item.ProductID}+${item.name}",45)
$oct.CutUrl(${siteurl})